package com.om.common;

import org.apache.http.impl.client.CloseableHttpClient;
import org.apache.spark.api.java.JavaRDD;

import java.io.IOException;
import java.security.KeyManagementException;
import java.security.NoSuchAlgorithmException;
import java.util.HashMap;

/**
 * @author zhxia
 * @date 2020/11/3 12:49
 */
public interface CommMethod {
    @Deprecated
    public  HashMap assemblydata(Object jsonData, String id) throws KeyManagementException, NoSuchAlgorithmException, IOException;
    public  HashMap assemblydataNew(CloseableHttpClient client, Object jsonData, String id) throws KeyManagementException, NoSuchAlgorithmException, IOException;
    @Deprecated
    public  HashMap getLocationByIP(String ip, String index, String id) throws NoSuchAlgorithmException, KeyManagementException;
    public  HashMap getLocationByIPNew(CloseableHttpClient client, String ip, String index, String id) throws NoSuchAlgorithmException, KeyManagementException;
    public JavaRDD dealData(JavaRDD javaRDD,String[] vhosts);
    public String[] parseUserAgent(String userAgent);
}
